<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>Sharing connections</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="mysqlnd-mux.connection_pool.html">Connection pool</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="mysqlnd-mux.setup.html">安装／配置</a></div>
 <div class="up"><a href="mysqlnd-mux.concepts.html">Concepts</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="mysqlnd-mux.sharing_connections" class="section">
  <h2 class="title">Sharing connections</h2>
  <p class="para">
   The PHP mysqlnd connection multiplexing plugin changes the relationship
   between a users connection handle and the underlying MySQL connection.
   Without the plugin, every MySQL connection belongs to exactly one
   user connection at a time. The multiplexing plugin changes.
   A MySQL connection is shared among multiple user handles.
   There no one-to-one relation if using the plugin.
  </p>
  <p class="para">
   Sharing pooled connections has an impact on the connection state.
   State changing operations from multiple user handles pointing to one
   MySQL connection are not isolated from each other. If, for example,
   a session variable is set through one user connection handle,
   the session variable becomes visible to all other user handles that
   reference the same underlying MySQL connection.
  </p>
  <p class="para">
   This is similar in concept to connection state related phenomens
   described for the PHP mysqlnd replication and load balancing plugin.
   Please, check the
   <a href="book.mysqlnd-ms.html" class="link">PECL/mysqlnd_ms documentation</a> for
   more details on the state of a connection.
  </p>
  <p class="para">
   The proof-of-concept takes no measures to isolate multiplexed
   connections from each other.
  </p>
 </div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="mysqlnd-mux.connection_pool.html">Connection pool</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="mysqlnd-mux.setup.html">安装／配置</a></div>
 <div class="up"><a href="mysqlnd-mux.concepts.html">Concepts</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>
